package com.bjc.base.bean.response;

import java.math.BigDecimal;

import lombok.Getter;
import lombok.Setter;
import lombok.ToString;

/**
 * <p>
 * 订单
 * </p>
 *
 * @author 许自辉
 * @since 2018-06-10
 */
@Getter
@Setter
@ToString
public class OrderVO extends BasesVO {

    /**
     * 用户id
     */
	private Integer uid;
	/**
	 * 微信订单号
	 */
	private String outTradeNo;
    /**
     * 订单类型(borrow租、buy买)
     */
	private String orderType;
	private String orderTypeName;
    /**
     * 人民币金额
     */
	private BigDecimal rmbAmount;
    /**
     * 小鱼币金额
     */
	private BigDecimal xybAmount;
    /**
     * 订单状态(-1为废弃状态,0为初始状态,1为订单已生效状态,2为待支付状态,3为已支付状态,4为已完成状态)
     */
	private Integer status;

	private String statusName;
	
	public String getOrderTypeName() {
		if("borrow".equals(orderType)) {
			return "借阅";
		}
		if("buy".equals(orderType)) {
			return "购买";
		}
		return "未知";
	}


}
